package com.soaring.message.util;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * 给静态属性赋值
 */
@Component
@PropertySource(value= {"classpath:AliyunMessage.properties"})
public class SystemConfig {


    public  static  String  name;

    public  static  String  value;

    public  static  String  type;

    @Value("${value.name}")
    public void setName(String name) { SystemConfig.name = name; }
    @Value("${value.value}")
    public  void setValue(String value) {
        SystemConfig.value = value;
    }
    @Value("${value.type}")
    public void setType(String type) { SystemConfig.type = type; }
    public  static void main(String[] args){
        System.out.println(SystemConfig.name) ;
    }

}
